package cn.vcjf.weapp.api.goods.service;

import cn.vcjf.weapp.api.goods.entity.GoodsGroup;
import com.baomidou.mybatisplus.service.IService;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author zhengzihang
 * @since 2018-09-25
 */
public interface GoodsGroupService extends IService<GoodsGroup> {

	GoodsGroup selectRepertoryForUpdate(GoodsGroup goodsGroup);

	GoodsGroup selectRepertoryForUpdate(int id);

	/**
	 * 增加库存
	 * @param goodsGroup
	 * @return
	 */
	int addGoodsGroupRepertory(GoodsGroup goodsGroup);
	int addGoodsGroupRepertory(int id,int num);

	/**
	 * 减少库存
	 *
	 * @param goodsGroup
	 * @return
	 */
	int reduceGoodsGroupRepertory(GoodsGroup goodsGroup);
	int reduceGoodsGroupRepertory(int id,int num);
}
